package com.ruoyi.system.service.impl;

import java.util.List;

import com.ruoyi.system.domain.TPosition;
import com.ruoyi.system.mapper.TPositionMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.TDepartmentMapper;
import com.ruoyi.system.domain.TDepartment;
import com.ruoyi.system.service.ITDepartmentService;

/**
 * 部门信息Service业务层处理
 * 
 * @author 徐国洋
 * @date 2025-02-23
 */
@Service
public class TDepartmentServiceImpl implements ITDepartmentService 
{
    @Autowired
    private TDepartmentMapper tDepartmentMapper;



    /**
     * 查询部门信息
     * 
     * @param id 部门信息主键
     * @return 部门信息
     */
    @Override
    public TDepartment selectTDepartmentById(Long id)
    {
        return tDepartmentMapper.selectTDepartmentById(id);
    }

    /**
     * 查询部门信息列表
     * 
     * @param tDepartment 部门信息
     * @return 部门信息
     */
    @Override
    public List<TDepartment> selectTDepartmentList(TDepartment tDepartment)
    {
        return tDepartmentMapper.selectTDepartmentList(tDepartment);
    }

    /**
     * 新增部门信息
     * 
     * @param tDepartment 部门信息
     * @return 结果
     */
    @Override
    public int insertTDepartment(TDepartment tDepartment)
    {
        return tDepartmentMapper.insertTDepartment(tDepartment);
    }

    /**
     * 修改部门信息
     * 
     * @param tDepartment 部门信息
     * @return 结果
     */
    @Override
    public int updateTDepartment(TDepartment tDepartment)
    {
        return tDepartmentMapper.updateTDepartment(tDepartment);
    }

    /**
     * 批量删除部门信息
     * 
     * @param ids 需要删除的部门信息主键
     * @return 结果
     */
    @Override
    public int deleteTDepartmentByIds(Long[] ids)
    {
        return tDepartmentMapper.deleteTDepartmentByIds(ids);
    }

    /**
     * 删除部门信息信息
     * 
     * @param id 部门信息主键
     * @return 结果
     */
    @Override
    public int deleteTDepartmentById(Long id)
    {
        return tDepartmentMapper.deleteTDepartmentById(id);
    }
}
